package com.gjl.system.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.gjl.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.gjl.common.annotation.Excel;

/**
 * 微信小程序登录授权对象 wx_auth_user
 * 
 * @author gjl
 * @date 2025-10-28
 */
public class WxAuthUser extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 授权ID */
    private Long id;

    /** 角色类型 */
    private String roleType;

    /** 第三方平台用户唯一ID */
    @Excel(name = "第三方平台用户唯一ID")
    private String uuid;

    /** 系统用户ID */
    @Excel(name = "系统用户ID")
    private Long userId;

    /** 登录账号 */
    @Excel(name = "登录账号")
    private String userName;

    /** 用户昵称 */
    @Excel(name = "用户昵称")
    private String nickName;

    /** 头像地址 */
    @Excel(name = "头像地址")
    private String avatar;

    /** 用户邮箱 */
    @Excel(name = "用户邮箱")
    private String email;

    /** 最后登录IP */
    @Excel(name = "最后登录IP")
    private String loginIp;

    /** 最后登录时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "最后登录时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date loginDate;

    /** 手机号码 */
    @Excel(name = "手机号码")
    private String phoneNumber;

    /** 用户来源 */
    @Excel(name = "用户来源")
    private String source;

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }

    public String getRoleType() {
        return roleType;
    }

    public void setRoleType(String roleType) {
        this.roleType = roleType;
    }

    public void setUuid(String uuid)
    {
        this.uuid = uuid;
    }

    public String getUuid() 
    {
        return uuid;
    }

    public void setUserId(Long userId) 
    {
        this.userId = userId;
    }

    public Long getUserId() 
    {
        return userId;
    }

    public void setUserName(String userName) 
    {
        this.userName = userName;
    }

    public String getUserName() 
    {
        return userName;
    }

    public void setNickName(String nickName) 
    {
        this.nickName = nickName;
    }

    public String getNickName() 
    {
        return nickName;
    }

    public void setAvatar(String avatar) 
    {
        this.avatar = avatar;
    }

    public String getAvatar() 
    {
        return avatar;
    }

    public void setEmail(String email) 
    {
        this.email = email;
    }

    public String getEmail() 
    {
        return email;
    }

    public void setLoginIp(String loginIp) 
    {
        this.loginIp = loginIp;
    }

    public String getLoginIp() 
    {
        return loginIp;
    }

    public void setLoginDate(Date loginDate) 
    {
        this.loginDate = loginDate;
    }

    public Date getLoginDate() 
    {
        return loginDate;
    }

    public void setPhoneNumber(String phoneNumber) 
    {
        this.phoneNumber = phoneNumber;
    }

    public String getPhoneNumber() 
    {
        return phoneNumber;
    }

    public void setSource(String source) 
    {
        this.source = source;
    }

    public String getSource() 
    {
        return source;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("authId", getId())
            .append("uuid", getUuid())
            .append("userId", getUserId())
            .append("userName", getUserName())
            .append("nickName", getNickName())
            .append("avatar", getAvatar())
            .append("email", getEmail())
            .append("loginIp", getLoginIp())
            .append("loginDate", getLoginDate())
            .append("phoneNumber", getPhoneNumber())
            .append("source", getSource())
            .append("createTime", getCreateTime())
            .toString();
    }
}
